<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>知识星球L站 - 在线交友</title>
    <link rel="stylesheet" href="styles.css">
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
</head>
<body>
    <div class="container">
        <div id="loginForm" class="form-container">
            <div class="author-info">
                <h1 style="text-align: center; margin-bottom: 10px;">在线交友</h1>
            </div>
           
            <div class="input-group">
                <i class="fas fa-user"></i>
                <input type="text" id="username" placeholder="用户名">
            </div>
            <div class="input-group">
                <i class="fas fa-lock"></i>
                <input type="password" id="password" placeholder="密码">
            </div>
            <button onclick="login()">登 录</button>
            <button onclick="showRegister()">注册新用户</button>
        </div>
        
        <div id="chatContainer" class="chat-container" style="display: none;">
            <div class="chat-sidebar">
                <div class="sidebar-header">
                    <h3>我的好友</h3>
                    <button class="logout-btn" onclick="logout()">
                        <i class="fas fa-sign-out-alt"></i>
                    </button>
                </div>
                <div id="onlineUsers"></div>
            </div>
            <div class="chat-main">
                <div id="messageArea"></div>
                <div class="chat-input">
                    <input type="text" id="messageInput" placeholder="输入消息...">
                    <button onclick="sendMessage()">发送</button>
                </div>
            </div>
           <!-- <div class="footer-info">
                <p>© 2024 知识星球L站. All rights reserved.</p>
            </div> -->
        </div>
    </div>
    <script src="main.js"></script>
</body>
</html> 